package jzOffer;

public class Num50 {
    public char firstUniqChar(String s) {
        int[] arr=new int[26];
        char[] c=s.toCharArray();
        for(int i=0;i<c.length;i++){
            arr[c[i]-'a']++;
        }
        for(int i=0;i<c.length;i++){
            if(arr[c[i]-'a']==1) return c[i];
        }
        return ' ';
    }
}
